[#ftl]
[#assign commandName = tab.typeName?uncap_first /]
[#assign action = "save" /]
[#assign nlsMap = nlsMap!{} /]
<sf:form id="${commandName}-form" action="${action}" method="post" commandName="${commandName}">
    <table class="table-module01" cellpadding="0" cellspacing="0">
        <tbody>
        [#list tab.columns as col]
            [#assign path = col.property /]
            [#assign code = nlsMap[tab.fullTypeName + '.' + path]!tab.fullTypeName + '.' + path/]
            [#assign type = col.javaTypeName?lower_case /]
        <tr>
            <th width="130" align="right">
                <sf:label path="${path}" for="${path}"><spring:message code="${code}" />:</sf:label>
            </th>
            <td>
            [#if type == 'boolean']
                <sf:input path="${path}" cssErrorClass="error" />
            [#elseif type == 'date']
                <sf:input path="${path}" cssErrorClass="error" cssClass="Wdate" onfocus="WdatePicker({dateFmt:'yyyy-MM-dd'})"/>
                [#-- 转义问题,所以这里使用 --]
                [#--<sf:input id="startTime" path="startTime" cssErrorClass="error" cssClass="Wdate" htmlEscape="false"  onfocus="WdatePicker({dateFmt:'yyyy-MM-dd', maxDate:'#F{$dp.$D(&#92;x27endTime&#92;x27)||&#92;x272099-12-31&#92;x27}'})"/>--]
            [#else]
                <sf:input path="${path}" cssErrorClass="error"/>
            [/#if]
                <sf:errors path="${path}" element="label" cssClass="error" for="${path}"/>
            </td>
        </tr>
        [/#list]
        </tbody>
    </table>
</sf:form>